﻿@using System.Diagnostics;
@using System.Collections;
@using System.Reflection;
@using System.Runtime.Versioning;
@using Microsoft.AspNetCore.Http
@using NewLife.Common;
@using NewLife.Serialization
@inject IHttpContextAccessor HttpContextAccessor
@{
    Layout = NewLife.Cube.Setting.Current.Layout;
    var session = HttpContextAccessor.HttpContext.Session;
    ViewBag.Title = "Session列表";
}
<table class="table table-bordered table-hover table-striped table-condensed">
    <tr>
        <th colspan="6">
            Session列表(@session.Keys.Count())
        </th>
    </tr>
    <tr>
        <th>名称</th>
        <th>类型</th>
        <th>数值</th>
    </tr>
    @foreach (String item in session.Keys)
        {
        <tr>
            <td>@item</td>
            <td>@session.Get(item,typeof(Object)).GetType().FullName</td>
            <td>@session.Get(item, typeof(Object)).ToJson()</td>
        </tr>
        }
</table>
